/**
 * 抖音统计
 * - 使用自定义封装组件，简化代码，统一管理。
 * - 2025-08-12 18:05:04 tzj
 * */

import withBasePage from "../../components/BaseComponent/withBasePage";
import {mrhzApi} from "../../services/basic";

// 要显示的form表单
const formItemList =
    [
        "companies",
        {
            name:"dateRange",
            label:'留资日期'
        },
        "zwSelect"
    ];

// 显示的按钮
const buttons = ["query", "export",];
// 表格列信息
const columns = [
    {
        title: '抖音客服',
        dataIndex: 'xm',
        width: "50%",
        sumName: "合计",
    },
    {
        title: '总留资',
        dataIndex: 'zlz',
        sorter: true,
    },
]

export default withBasePage({
    state:{
        formItemList,
        buttons,
        // columns,
        filename: "抖音统计",
        queryAll: true,
        sumRow: true,
    },
    columns,
    queryApi: mrhzApi.selectPageDy,
    hasLzModal:true,
    onRowDoubleClick(record) {
        const params = {
            ...this.form.dataForm,
            // yybm: record.yybm,
            dykh: record.gh
        }
        const config = {
            // queryApi: mrhzApi.selectPagecj,
            // columns: Dictionary.dealColumns,
            // tableTitle: "成交详情",
            // // width: 1200
        }
        this.lzModalRef.open(params, config);
    },
})(() => null);
